<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <title>手机设置</title>
  <meta name="renderer" content="webkit">
  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  
    {include file="public/css"}
    {include file="public/js"}
</head>
<body>

<!-- 后台面包导航 -->
{:get_admin_breadcrumb()}

<blockquote class="layui-elem-quote" style="margin-top:10px;">说明：配置手机端基本信息</blockquote>

<form class="layui-form" action="">
<input type="hidden"  name="groupname" value="{$Request.action}">

<div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief">
  <ul class="layui-tab-title">
    <li class="layui-this">基本设置</li>
    <!-- <li >APP设置</li> -->
  </ul>

  <div class="layui-tab-content">


  <div class="layui-tab-item layui-show"> 
      <div class="layui-form-item">
        <label class="layui-form-label">手机版状态</label>
         <div class="layui-input-block">
             <input type="radio" name="data[status]" value="1" {if $settings.mobile.status ==1}checked{/if} title="开启" checked="">
             <input type="radio" name="data[status]" value="0" {if $settings.mobile.status ==0}checked{/if} title="关闭">
            </div>
      </div>

<!--       <div class="layui-form-item">
        <label class="layui-form-label">手机名称</label>
        <div class="layui-input-inline">
          <input type="text" name="data[name]" lay-verify="title" autocomplete="off" placeholder="" class="layui-input" value="{$settings.mobile.name}">
        </div>
      </div> -->
      <div class="layui-form-item">
        <label class="layui-form-label">自动跳转</label>
            <div class="layui-input-block">
             <input type="radio" name="data[auto_jump]" value="1" {if $settings.mobile.auto_jump ==1}checked{/if} title="开启" checked="">
             <input type="radio" name="data[auto_jump]" value="0" {if $settings.mobile.auto_jump ==0}checked{/if} title="关闭">
            </div>
      </div>
    <!--   <div class="layui-form-item">
        <label class="layui-form-label">苹果APP下载地址</label>
        <div class="layui-input-inline">
          <input type="text" name="data[apple_url]" lay-verify="title" autocomplete="off" placeholder="" class="layui-input" value="{$settings.mobile.apple_url}">
        </div>
      </div>
      <div class="layui-form-item">
        <label class="layui-form-label">安卓APP下载地址</label>
        <div class="layui-input-inline">
          <input type="text" name="data[android_url]" lay-verify="title" autocomplete="off" placeholder="" class="layui-input" value="{$settings.mobile.android_url}">
        </div>
      </div> -->
</div>
 <div class="layui-tab-item">


<div class="layui-form-item">
          <label class="layui-form-label">App ID</label>
          <div class="layui-input-inline">
            <input type="text" name="data[getui_appid]" lay-verify="title" autocomplete="off" placeholder="" class="layui-input" value="{$settings.mobile.getui_appid}">
          </div>
           <div class="layui-form-mid layui-word-aux">{:about('数字编号')}</div>
        </div>

<div class="layui-form-item">
          <label class="layui-form-label">App Secret</label>
          <div class="layui-input-inline">
            <input type="text" name="data[getui_appid]" lay-verify="title" autocomplete="off" placeholder="" class="layui-input" value="{$settings.mobile.getui_appid}">
          </div>
           <div class="layui-form-mid layui-word-aux">{:about('建议32位加密字符串')}</div>
        </div>
 <fieldset class="layui-elem-field">
  <legend>APP推送</legend>
  <div class="layui-field-box">
<div class="layui-form-item">
          <label class="layui-form-label">个推appid</label>
          <div class="layui-input-inline">
            <input type="text" name="data[getui_appid]" lay-verify="title" autocomplete="off" placeholder="" class="layui-input" value="{$settings.mobile.getui_appid}">
          </div>
           <div class="layui-form-mid layui-word-aux">{:ql_link('申请接口','http://www.getui.com/')}</div>
        </div>    
<div class="layui-form-item">
          <label class="layui-form-label">个推appid</label>
          <div class="layui-input-inline">
            <input type="text" name="data[getui_appid]" lay-verify="title" autocomplete="off" placeholder="" class="layui-input" value="{$settings.mobile.getui_appid}">
          </div>
           <div class="layui-form-mid layui-word-aux">{:ql_link('申请接口','http://www.getui.com/')}</div>
        </div>


         <div class="layui-form-item">
          <label class="layui-form-label">个推appkey</label>
            <div class="layui-input-inline">
              <input type="text" name="data[getui_appkey]" lay-verify="title" autocomplete="off" placeholder="" class="layui-input" value="{$settings.mobile.getui_appkey}">
            </div>
             <div class="layui-form-mid layui-word-aux">{:about('个推appkey')}</div>
         </div>

         <div class="layui-form-item">
            <label class="layui-form-label">个推appsecret</label>
            <div class="layui-input-inline">
              <input type="text" name="data[getui_appsecret]" lay-verify="title" autocomplete="off" placeholder="" class="layui-input" value="{$settings.mobile.getui_appsecret}">
            </div>
             <div class="layui-form-mid layui-word-aux">{:about('个推appsecret')}</div>
         </div>


  </div>
</fieldset>


         
</div>

    <div class="layui-form-item">
              <label class="layui-form-label"></label>
                <div class="layui-input-block">
                    <button class="layui-btn layui-btn-normal" lay-submit="" lay-filter="form">确 定</button>
                </div>
     </div>
  </div>

</div> 

</form>

<script>
layui.use('form', function(){
  var form = layui.form;
  
  //监听提交
  form.on('submit(form)', function(data){
    // layer.msg(JSON.stringify(data.field));
    var data =data.field;
    $.post("{:url('settings/update')}",data,function(json){
       if(json.code == 0){
           layer.msg(json.msg);
       }else if(json.code == -1){
           layer.msg(json.msg);
       }
    });
    return false;
  });
});
</script>


</body>

</html>